<?php //print_r($lg);?>
<div id="header">

	<div class="container">

		<h1 id="logo">
			<a href="<?php echo base_url().$lang?>/pages/index">
				<img src="<?php echo base_url();?>img/logo.png" alt="Travel Guide">
			</a>
		</h1>
		
		<div id="header-ads">
		
			<!-- <a href="http://themeforest.net/?ref=smuliii"><img src="http://envato.s3.amazonaws.com/referrer_adverts/tf_468x60_v4.gif" alt="tf_468x60_v4" /></a> -->
			
		</div><!-- end #header-ads -->

	</div><!-- end .container -->

</div><!-- end #header -->

<div id="nav">

	<div class="container">

		<ul>
			<li <?php if ($page=="home"){?>class="active" <?php } ?>><a href="<?php echo base_url().$lang?>/pages/index"><?php echo lang("Home");?></a></li>
			<li <?php if ($page=="tours"){?> class="active" <?php } ?> ><a href="<?php echo base_url().$lang?>/pages/tours"><?php echo lang("bus_tour")?></a>
				<ul>
					<?php foreach ($lg as $l){?>
					<li><a href="<?php echo base_url().$lang.'/pages/tours/'.$l["idweb_group"]?>-bustours"><?php echo $l["name_$lang"]; ?></a></li>
					<?php }?>
					
				</ul>
			</li>
			<li><a href="http://www.anrdoezrs.net/click-6479417-10786230"  target="_blank"><?php echo lang("hotel");?></a></li>
			<li><a href="http://www.dpbolvw.net/click-6479417-10790631" target="_blank"><?php echo lang("flights")?></a></li>
			<li><a href="http://www.anrdoezrs.net/click-6479417-10786230" target="_blank"><?php echo lang("cruise");?></a><img src="http://www.lduhtrp.net/image-6479417-10786230" width="1" height="1" border="0"/></li>
			<li <?php if ($page=="aboutus"){?> class="active" <?php } ?> ><a href="<?php echo base_url().$lang?>/pages/aboutus"><?php echo lang("aboutus");?></a></li>
			<li <?php if ($page=="contactus"){?> class="active" <?php } ?>  ><a href="<?php echo base_url().$lang?>/pages/contactus"><?php echo lang("contactus");?></a></li>
		</ul>
		
		<div id="search">
		
			<!--  <input type="text" class="input" value="" placeholder="Keyword search here...">
			<input type="submit" class="submit" value="Go">-->
			<?php 
            	   	$url_orginal=$this->uri->uri_string();
            	   if( $this->uri->segment(1)=='en'){
            	   
            	   	$url_redirect_fr=preg_replace("/^en/","fr",$url_orginal);
            	   	$url_redirect_cn=preg_replace("/^en/","cn",$url_orginal);
            	   	$url_redirect_en=$url_orginal;
            	   	
            	   }else if($this->uri->segment(1)=='fr')
            	   {
            	   		$url_redirect_en=preg_replace("/^fr/","en",$url_orginal);
            	   		$url_redirect_cn=preg_replace("/^fr/","cn",$url_orginal);
            	   		$url_redirect_fr=$url_orginal;
            	   }
            	   else  if($this->uri->segment(1)=='cn'){
            	   	
            	   		$url_redirect_en=preg_replace("/^cn/","en",$url_orginal);
            	   		$url_redirect_fr=preg_replace("/^cn/","fr",$url_orginal);
            	   		$url_redirect_cn=$url_orginal;
            	   		} else
            	   		{
            	   				$url_redirect_fr="fr/".$url_orginal;	
				            	$url_redirect_cn="cn/".$url_orginal;	
				            	$url_redirect_en="en/".$url_orginal;	
            	   			
            	   		}
            	   	if($lang=="en")
            	   	{	
            	   ?>
            	   <a style="text-decoration:none">English</a>&nbsp;&nbsp;<a href="<?php echo  base_url().$url_redirect_fr; ?>">Francaise</a>
            	   &nbsp;&nbsp;<a href="<?php echo  base_url().$url_redirect_cn; ?>">中文</a>
            	   
            	  <?php }elseif($lang=="fr"){?>
            	    <a href="<?php echo  base_url().$url_redirect_en; ?>" >English</a>&nbsp;&nbsp; <a  style="text-decoration:none">Francaise</a>
            	     &nbsp;&nbsp;<a href="<?php echo  base_url().$url_redirect_cn; ?>">中文</a>
            	  <?php }elseif("cn"){ ?>
            	  	  <a href="<?php echo  base_url().$url_redirect_en; ?>" >English</a>&nbsp;&nbsp; <a  href="<?php echo  base_url().$url_redirect_fr; ?>">Francaise</a>
            	     &nbsp;&nbsp;<a  style="text-decoration:none"">中文</a>
            	  	
            	<?php } ?> 
			
		</div><!-- end #search -->

	</div><!-- end .container -->

</div><!-- end #nav -->

<div id="nav-shadow"></div>
